n=int(input())
sum=0
op=1
for i in range(1,n+1):
    sum+=op*1/i
    op=-1*op
print(f"{sum:.4f}")
